class AddAnotherPermission < ActiveRecord::Migration
  def self.create_permission(name, role, level)
    Permission.new({'name'=>name, 'role'=>role, 'level'=>level}).save!
  end
  def self.destroy_permission(name, role, level)
    Permission.destroy({'name'=>name, 'role'=>role, 'level'=>level})
  end

  def self.up
    self.create_permission('update:user','super','1');
  end

  def self.down
  	self.destroy_permission('update:user','super','1');
  end
end
